import {IsNotEmpty, IsString, Length, IsNumber} from 'class-validator'
export class CreatePipelineDto {
    @IsNotEmpty()       // 使用装饰器验证 name字段
    @IsString()       // 验证name字段必须是字符串
    @Length(6, 10, {
        message: 'name长度必须在6到10之间'
    })
    name: string;
    
    @IsNumber()
    age: number;
    
}
